package com.guqiao.sdk

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle

class MainActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {

        var sdk:Sdk? = null

        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)
        sdk = Sdk()
        var callJavaMethodResult = sdk.callNativeMethod("java function")
        println("callJavaMethodResult:$callJavaMethodResult")
        var callJavaStaticMethodResult = Sdk.staticCallNativeMethod("java static function")
        println("callJavaStaticMethodResult:$callJavaStaticMethodResult")
        println("---------------------------------------------")
        println("Before Change java Field:${sdk.name}")
        sdk.changeJavaField();
        println("After Change Java Field:${sdk.name}")
        println("---------------------------------------------")
        println("Before Change java static Field:${Sdk.index}")
        sdk.changeJavaStaticField()
        println("After Change java static Field:${Sdk.index}")
    }
}